Optimal. Leaf size=87 \[ \frac {(e x)^n}{a e n}-\frac {2 b x^{-n} (e x)^n \tanh ^{-1}\left (\frac {\sqrt {a-b} \tan \left (\frac {1}{2} \left (c+d x^n\right )\right )}{\sqrt {a+b}}\right )}{a d e n \sqrt {a-b} \sqrt {a+b}} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.15, antiderivative size = 87, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 5, integrand size = 22, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.227, Rules used = {4208, 4204, 3783, 2659, 208} \[ \frac {(e x)^n}{a e n}-\frac {2 b x^{-n} (e x)^n \tanh ^{-1}\left (\frac {\sqrt {a-b} \tan \left (\frac {1}{2} \left (c+d x^n\right )\right )}{\sqrt {a+b}}\right )}{a d e n \sqrt {a-b} \sqrt {a+b}} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 208
Rule 2659
Rule 3783
Rule 4204
Rule 4208
Rubi steps
\begin {align*} \int \frac {(e x)^{-1+n}}{a+b \sec \left (c+d x^n\right )} \, dx &=\frac {\left (x^{-n} (e x)^n\right ) \int \frac {x^{-1+n}}{a+b \sec \left (c+d x^n\right )} \, dx}{e}\\ &=\frac {\left (x^{-n} (e x)^n\right ) \operatorname {Subst}\left (\int \frac {1}{a+b \sec (c+d x)} \, dx,x,x^n\right )}{e n}\\ &=\frac {(e x)^n}{a e n}-\frac {\left (x^{-n} (e x)^n\right ) \operatorname {Subst}\left (\int \frac {1}{1+\frac {a \cos (c+d x)}{b}} \, dx,x,x^n\right )}{a e n}\\ &=\frac {(e x)^n}{a e n}-\frac {\left (2 x^{-n} (e x)^n\right ) \operatorname {Subst}\left (\int \frac {1}{1+\frac {a}{b}+\left (1-\frac {a}{b}\right ) x^2} \, dx,x,\tan \left (\frac {1}{2} \left (c+d x^n\right )\right )\right )}{a d e n}\\ &=\frac {(e x)^n}{a e n}-\frac {2 b x^{-n} (e x)^n \tanh ^{-1}\left (\frac {\sqrt {a-b} \tan \left (\frac {1}{2} \left (c+d x^n\right )\right )}{\sqrt {a+b}}\right )}{a \sqrt {a-b} \sqrt {a+b} d e n}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.29, size = 80, normalized size = 0.92 \[ \frac {(e x)^n \left (\frac {2 b x^{-n} \tanh ^{-1}\left (\frac {(b-a) \tan \left (\frac {1}{2} \left (c+d x^n\right )\right )}{\sqrt {a^2-b^2}}\right )}{\sqrt {a^2-b^2}}+c x^{-n}+d\right )}{a d e n} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.64, size = 300, normalized size = 3.45 \[ \left [\frac {2 \, {\left (a^{2} - b^{2}\right )} d e^{n - 1} x^{n} + \sqrt {a^{2} - b^{2}} b e^{n - 1} \log \left (\frac {2 \, a b \cos \left (d x^{n} + c\right ) - {\left (a^{2} - 2 \, b^{2}\right )} \cos \left (d x^{n} + c\right )^{2} + 2 \, a^{2} - b^{2} - 2 \, {\left (\sqrt {a^{2} - b^{2}} b \cos \left (d x^{n} + c\right ) + \sqrt {a^{2} - b^{2}} a\right )} \sin \left (d x^{n} + c\right )}{a^{2} \cos \left (d x^{n} + c\right )^{2} + 2 \, a b \cos \left (d x^{n} + c\right ) + b^{2}}\right )}{2 \, {\left (a^{3} - a b^{2}\right )} d n}, \frac {{\left (a^{2} - b^{2}\right )} d e^{n - 1} x^{n} - \sqrt {-a^{2} + b^{2}} b e^{n - 1} \arctan \left (-\frac {\sqrt {-a^{2} + b^{2}} b \cos \left (d x^{n} + c\right ) + \sqrt {-a^{2} + b^{2}} a}{{\left (a^{2} - b^{2}\right )} \sin \left (d x^{n} + c\right )}\right )}{{\left (a^{3} - a b^{2}\right )} d n}\right ] \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {\left (e x\right )^{n - 1}}{b \sec \left (d x^{n} + c\right ) + a}\,{d x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [C] time = 1.07, size = 314, normalized size = 3.61 \[ \frac {x \,{\mathrm e}^{\frac {\left (-1+n \right ) \left (-i \pi \,\mathrm {csgn}\left (i e \right ) \mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i e x \right )+i \pi \,\mathrm {csgn}\left (i e \right ) \mathrm {csgn}\left (i e x \right )^{2}+i \pi \,\mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i e x \right )^{2}-i \pi \mathrm {csgn}\left (i e x \right )^{3}+2 \ln \relax (x )+2 \ln \relax (e )\right )}{2}}}{a n}+\frac {2 i \arctan \left (\frac {2 a \,{\mathrm e}^{i \left (d \,x^{n}+2 c \right )}+2 \,{\mathrm e}^{i c} b}{2 \sqrt {a^{2} {\mathrm e}^{2 i c}-{\mathrm e}^{2 i c} b^{2}}}\right ) e^{n} b \,{\mathrm e}^{\frac {i \left (-\pi n \,\mathrm {csgn}\left (i e \right ) \mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i e x \right )+\pi n \,\mathrm {csgn}\left (i e \right ) \mathrm {csgn}\left (i e x \right )^{2}+\pi n \,\mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i e x \right )^{2}-\pi n \mathrm {csgn}\left (i e x \right )^{3}+\pi \,\mathrm {csgn}\left (i e x \right ) \mathrm {csgn}\left (i e \right ) \mathrm {csgn}\left (i x \right )-\pi \,\mathrm {csgn}\left (i e \right ) \mathrm {csgn}\left (i e x \right )^{2}-\pi \,\mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i e x \right )^{2}+\pi \mathrm {csgn}\left (i e x \right )^{3}+2 c \right )}{2}}}{\sqrt {a^{2} {\mathrm e}^{2 i c}-{\mathrm e}^{2 i c} b^{2}}\, d e n a} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [F(-1)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 2.75, size = 223, normalized size = 2.56 \[ \frac {x\,{\left (e\,x\right )}^{n-1}}{a\,n}+\frac {b\,x\,\ln \left (2\,b\,x\,{\mathrm {e}}^{c\,1{}\mathrm {i}}\,{\mathrm {e}}^{d\,x^n\,1{}\mathrm {i}}\,{\left (e\,x\right )}^{n-1}-\frac {b\,x\,\left (a+b\,{\mathrm {e}}^{c\,1{}\mathrm {i}}\,{\mathrm {e}}^{d\,x^n\,1{}\mathrm {i}}\right )\,{\left (e\,x\right )}^{n-1}\,2{}\mathrm {i}}{\sqrt {a+b}\,\sqrt {a-b}}\right )\,{\left (e\,x\right )}^{n-1}}{a\,d\,n\,x^n\,\sqrt {a+b}\,\sqrt {a-b}}-\frac {b\,x\,\ln \left (2\,b\,x\,{\mathrm {e}}^{c\,1{}\mathrm {i}}\,{\mathrm {e}}^{d\,x^n\,1{}\mathrm {i}}\,{\left (e\,x\right )}^{n-1}+\frac {b\,x\,\left (a+b\,{\mathrm {e}}^{c\,1{}\mathrm {i}}\,{\mathrm {e}}^{d\,x^n\,1{}\mathrm {i}}\right )\,{\left (e\,x\right )}^{n-1}\,2{}\mathrm {i}}{\sqrt {a+b}\,\sqrt {a-b}}\right )\,{\left (e\,x\right )}^{n-1}}{a\,d\,n\,x^n\,\sqrt {a+b}\,\sqrt {a-b}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {\left (e x\right )^{n - 1}}{a + b \sec {\left (c + d x^{n} \right )}}\, dx \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________